<script>

export default {}

</script>

<template>
    <router-link to="/">重定向到首页</router-link>
  |
    <router-link to="/home">首页</router-link>
  |
    <router-link to="/blog">博客</router-link>
  |
    <router-link to="/school">学堂</router-link>

    <hr>

    <button @click="$router.push('/home')">首页</button>
    <button @click="$router.push({ path: '/blog' })">博客</button>
    <button @click="$router.push({ name: 'school' })">学堂</button>
  |
    <button @click="$router.push('/school/math')">数学界面</button>
    <button @click="$router.push({ path: '/school/english' })">英语界面</button>
    <button @click="$router.push({ name: 'school-math' })">数学界面</button>
  |
    <button @click="$router.push('/blog-content/110')">博客 110</button>
    <button @click="$router.push({ path: '/blog-content/120' })">博客 120</button>
    <button @click="$router.push({ name: 'blog-content' , params: { id: 119 } })">博客 119</button>

    <hr>
    <router-view/> <!-- 路由视图占位符（切换路由时，要展示的组件的地方） -->
</template>